package cn.tips.dmp.system.user.service.impl;

import cn.tips.dmp.system.user.entity.SystemUserPO;
import cn.tips.dmp.system.user.repository.SystemUserRepository;
import cn.tips.dmp.system.user.service.SystemUserService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

/**
 * @author pkb
 */
@Service
@RequiredArgsConstructor
public class SystemSystemUserServiceImpl implements SystemUserService {

    private final SystemUserRepository systemUserRepository;

    @Override
    public SystemUserPO readOneByPhoneNumber(String phoneNumber) {
        return systemUserRepository.findByPhoneNumberAndDeletedIsFalse(phoneNumber);
    }
}
